﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace TcpTestServer.DataLayer
{
    public class ConnectionEventArgs : EventArgs
    {
        
        public ConnectionStatusEnum Status
        {
            get
            {
                return _status;
            }
        }
        public string ComponentName
        {
            get
            {
                return _component_name;
            }
        }
        public string Address
        {
            get
            {
                return _address;
            }
        }
        public string ErrorMessage
        {
            get
            {
                return _error_message;
            }

        }
        
        public ConnectionEventArgs(ConnectionStatusEnum status,string component_name, string address)
        {
            _component_name = component_name;
            _address = address;
            _status = status;
        }
        public ConnectionEventArgs(ConnectionStatusEnum status, string component_name, string address, string error_message)
        {
            _component_name = component_name;
            _address = address;
            _status = status;
            _error_message = error_message;
        }
       
        private string _component_name;
        private string _address;
        private string _error_message;
        private ConnectionStatusEnum _status;
    }
}
